#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
int jec(int x, int y)
{
    if (y <= 1)
        return x;
    else return x * jec(x, y - 1);
}
int main()
{
    int n = 0, k = 0;
    scanf("%d %d", &n, &k);
    printf("%d", jec(n, k));
    return 0;
}